import request from '@/utils/request'

//  查询自查隐患列表
export function selfCheckQueryQuestion(params) {
  return request({
    url: '/business/defect/selfCheck/queryQuestion',
    method: 'get',
    params
  })
}

//  获取自查统计
export function selfCheckQuestionStatistic(params) {
  return request({
    url: '/business/defect/selfCheck/questionStatistic',
    method: 'get',
    params
  })
}

//  增加自查隐患
export function selfCheckAddQuestion(data) {
  return request({
    url: '/business/defect/selfCheck/addQuestion',
    method: 'post',
    data
  })
}

//  修改自查隐患
export function selfCheckUpdateQuestion(data) {
  return request({
    url: '/business/defect/selfCheck/updateQuestion',
    method: 'put',
    data
  })
}

// 删除自查隐患
export function selfCheckRemoveQuestion(params) {
  return request({
    url: `/business/defect/selfCheck/removeQuestion`,
    method: 'delete',
    params
  })
}
